package com.cbs.android.component.network.decoder;


import java.io.IOException;

import okhttp3.ResponseBody;

/**
 * Created by brochexu on 9/8/14.
 */
public class ByteArrayDecoder implements Decoder {
    public Object decode(ResponseBody body) throws IOException {
        return body.bytes();
    }

    @Override
    public String desc(Object result) {
        byte[] bytes = (byte[]) result;
        return String.format("bytes: size=%d", bytes.length);
    }
}
